package com.pu.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.pu.dto.ShoppingCartDTO;
import com.pu.entity.ShoppingCart;

import java.util.List;

/**
 * @Author Yusc
 * @Date 2023/10/31 23:20
 * @Version
 * @Description 购物车模块
 **/
public interface ShoppingCartService extends IService<ShoppingCart> {
    /**
     * @param shoppingCartDTO 前端传递的数据
     * @auther: Yusc
     * @date 2023/10/31 23:23
     * @Description 添加购物车
     */
    void addShoppingCart(ShoppingCartDTO shoppingCartDTO);

    /**
     * @auther: Yusc
     * @date 2023/11/1 16:20
     * @Description 查看购物车数据
     */
    List<ShoppingCart> showShoppingCart();

    /**
     * @param shoppingCartDTO 前端传递的数据
     * @auther: Yusc
     * @date 2023/11/1 16:32
     * @Description 删除购物车中一个商品
     */
    void subShoppingCart(ShoppingCartDTO shoppingCartDTO);

    /**
    * @auther: Yusc
    * @date 2023/11/1 16:39
    * @Description 清空购物车
    */
    void cleanShoppingCart();
}
